Add search-first variable explorer with computation trees#10
Draft
PavelMakarchuk wants to merge 12 commits intomasterfrom
Draft
Add search-first variable explorer with computation trees#10PavelMakarchuk wants to merge 12 commits intomasterfrom
PavelMakarchuk wants to merge 12 commits intomasterfrom
Conversation
Replace the old Variables page (which just listed programs with GitHub links) with a full explorer of all ~4K variables from the metadata API. Features: - Search across name, label, description, module path, entity, and type - Multi-word search (each word matched independently across all fields) - Level filter pills: Federal, State, Local, Territories, Contrib, Household - Grouped browse mode by agency/state/locality when not searching - Expandable computation tree showing adds/subtracts recursively - Shared metadata cache between variables and programs pages Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
- Replace flat group list with drill-in level cards (Federal, State, etc.) - Remove entity filter and input/computed filter toggle (keep as label with tooltip) - Add level filter pills when searching - Fix adds/subtracts which can be objects from the API, not just arrays Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…trib category - Replace flat variable list with visual drill-in: level cards → sub-group cards/tiles → variable list - Add StateTileGrid with 2-letter state codes and intensity-based opacity - Add SubGroupCardGrid for federal agencies, local, household, territories - Embed flowchart iframe at bottom that updates when clicking "View in flowchart" on a variable - Remove contributed/reform categories (deprecated paths) - Add level filter pills to search mode Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Create ParameterExplorer with same drill-in pattern as variables (level → sub-group → list) - Show value history timeline, current value badge, unit, and GitHub source link - Filter to leaf parameters only (exclude nodes and contrib) - Extract shared categorization logic to shared/categoryUtils.ts - Refactor VariableExplorer to use shared utils Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Fix branch: master → main across all GitHub URLs - Fix variable source links to point to .py files (blob) not directories (tree) - Add 'reform' level for gov.contrib/contrib parameters - Remove contrib filter from parameter explorer so reform params are visible Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Add scripts/fetch-metadata.js to download US/UK metadata at build time
- Write to public/metadata-{country}.json, served from Vercel CDN
- Update fetchMetadata.ts to try static file first, fall back to live API
- Update build script to run fetch before tsc/vite
- Add parameter group intermediate navigation level
- Turns ~67s API load into ~1-2s CDN load
Requires deploy hooks from policyengine-us and policyengine-uk to trigger
rebuilds when new model versions are released.
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…tion - Direct YAML file links via pre-built param tree (longest-prefix match) - Build script fetches GitHub repo tree for exact file mapping - Truncate long parameter paths in cards - Filter out 3,355 abolition parameters (internal toggles) - Add behavioral responses description to Simulation sub-group Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
…le colors Replace flat parameter group list with hierarchical folder navigation that mirrors the actual parameter file structure. Sub-folders auto-collapse when they have only one child. Remove intensity-based color scaling from state tiles so all states appear with uniform color. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Scale the iframe to 75% using CSS transform so more of the computation flowchart is visible within the same viewport area. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
Use a proper lookup for entity display names (e.g. tax_unit → Tax Unit, spm_unit → SPM Unit, benunit → Benefit Unit) in both card badges and detail metadata. Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Rewrite VariableExplorer with folder tree navigation matching parameter explorer - Add clickable breadcrumb path navigation (GitHub-style) - Add Google-style numbered pagination for large groups - Add loading indicator for flowchart iframe - Remove inaccurate "N variables across M programs" subtitle - Remove unused VariableList component Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
- Count parameters at YAML file level instead of per-leaf (67k → 3.6k) - Handle array/list parameter values with pill tags - Collapse projected/uprated values (2026+) behind expandable toggle - Show date ranges in value history (from → until) - Fix long label overflow with word-break in folder cards - Filter gov.puf variables from variable explorer - Fix Vercel config: set framework to Vite with correct output dir Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Test plan
#/rules/variablesand verify variables load from the API?country=ukto verify UK variables load correctly🤖 Generated with Claude Code